<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<div>

</div>
<script>
    var params = location.search.substr(1);     //substr('起始位置',截取到第几个如果为空默认截取到最后一个)截取字符串
    var arr = params.split('=');        //split() 字符串分隔符
    var div = document.querySelector('div');
    div.innerHTML = arr[1];
    if (navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i)){
        window.location.href = '';  //手机
    } else {
        window.location.href = '';  //电脑
    }
</script>
</body>
</html>